﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="teacherinfo.aspx.cs" Inherits="WebApplication2.WebForm2" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <title></title>
</head>
<body>
     <form id="form1" runat="server">
        姓名:<asp:TextBox ID="tb_name" runat="server"></asp:TextBox>
        <asp:Button ID="Button2" runat="server" OnClick="Button2_Click" Text="查询" Width="85px" />
&nbsp;
        <asp:Button ID="btn_add" runat="server" OnClick="btn_add_Click" Text="添加" Width="87px" />
        <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" CellPadding="4" ForeColor="#333333" GridLines="None" Height="306px" OnSelectedIndexChanged="GridView1_SelectedIndexChanged" Width="728px">
            <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
            <Columns>
                <asp:BoundField DataField="tno" HeaderText="教师号" />
                <asp:BoundField DataField="password" HeaderText="密码" />
                <asp:BoundField DataField="tname" HeaderText="教师姓名" />
                <asp:BoundField DataField="sex" HeaderText="性别" />
                <asp:TemplateField HeaderText="操作">
                    <ItemTemplate>
                        <asp:Button ID="Button1" runat="server" Height="25px" Text="删除" Width="59px" CommandArgument='<%# Eval("tno") %>' OnCommand="Button1_Command" />
                        &nbsp;
                        <asp:Button ID="btn_edit" runat="server" CommandArgument='<%# Eval("tno") %>' Height="26px" OnCommand="btn_edit_Command" Text="修改" Width="59px" />
                    </ItemTemplate>
                </asp:TemplateField>
            </Columns>
            <EditRowStyle BackColor="#999999" />
            <FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
            <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
            <PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
            <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
            <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
            <SortedAscendingCellStyle BackColor="#E9E7E2" />
            <SortedAscendingHeaderStyle BackColor="#506C8C" />
            <SortedDescendingCellStyle BackColor="#FFFDF8" />
            <SortedDescendingHeaderStyle BackColor="#6F8DAE" />
        </asp:GridView>
    </form>
</body>
</html>
